2023-08-31

Agenda

  • Project presentation & objectives

  • Package RetakeExamF

    • Description
    • Functions
    • Maze App
  • Limitations & future work

Project presentation (1)

  • The project is focused on building mazes. Exploring different algorithms related to the maze conception and conciliate these with R code.

Proejct objectives (2)

  • The goal of this project is to develop an R package that generates mazes using various maze generation algorithms.

  • Create an interactive app where users can create their own maze and visualize the solution.

Package RetakeExamF

Description

RetakeExamF is a dynamic R package that empowers users to craft captivating mazes using the Depth-First Search (DFS) and Recursive Backtracking algorithms. The package provides a user-friendly platform to generate mazes of varying complexities.

source :https://freesvg.org/isometric-cardboard-box

Recursive backtracking function

Plot maze

RetakeExamF::rb_maze(31,31) # maze generation

Functions - myGraph() - plotmyMaze()

Example of the functions usage :

# myGraph() 
Example_maze <- RetakeExamF::myGraph (nrows = 5,ncols = 9) 
#plotmyMaze()
RetakeExamF::plotmyMaze(Example_maze,nrows= 5,ncols = 9)

Functions - dfs_method()

Plot DFS

#dfs_method()
Example_maze <- RetakeExamF::myGraph (nrows = 5,ncols = 9)
Example_maze<-RetakeExamF::dfs_method(GraphMade = Example_maze)

RetakeExamF::plotmyMaze(Example_maze,nrows= 5,ncols = 9)

Functions - solverGraph()

# solver visualization
RetakeExamF::solverGraph(Example_maze,nrows= 5,ncols = 9)

Functions - myMazeShinyApp3()

Example function that runs the app on shiny :

Maze App

Now, let’s run the app !

Limitations & future work

Limitations

  • Lack of user features - (i.e. walk around the maze )
  • Lack of creativity (try out different approaches)
  • Bottleneck issue when increasing the size of the maze

Future work

  • More algorithm variety to build mazes
  • Homework assignment : Solve the maze
  • More interactivity ➡️ Create a game ?